CC=/home/saisi/NtArea/gcc-arm/gcc-arm-10.3-2021.07-x86_64-aarch64-none-linux-gnu/bin/aarch64-none-linux-gnu-gcc
CFLAGS=-Wall																																							
LDFLAGS=-lpthread -lrt
TARGET=server
LIBTARGET=libservr.a
LIBOBJ=serve_lib.o

all: $(TARGET)

$(TARGET): server.c $(LIBTARGET)
	$(CC) $(CFLAGS) -o $(TARGET) server.c $(LIBTARGET) $(LDFLAGS)

$(LIBTARGET):$(LIBOBJ)
	ar rcs $(LIBTARGET) $(LIBOBJ)

$(LIBOBJ): serve_lib.c
	$(CC) $(CFLAGS) -c serve_lib.c -o $(LIBOBJ)

clean:
	rm -f $(TARGET) $(LIBOBJ) $(LIBTARGET)
